﻿<!DOCTYPE HTML>
<html>
<head>
	<meta charset="UTF-8">
	<meta http-equiv="X-UA-Compatible" content="IE=10,IE=9,IE=8">
	<meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=0, minimum-scale=1.0, maximum-scale=1.0">
	<title><?php echo $type_seo['type_name']?> - <?php echo $config['site_name']?></title>
	<meta name="keywords" content="<?php echo $type_seo['keywords']?>">
	<meta name="description" content="<?php echo $one['introduction']?>">
	<link rel='dns-prefetch' href='//cdn.bootcss.com' />
	<link rel='dns-prefetch' href='//s.w.org' />
	<link rel='stylesheet' id='style-css'  href='__HOME__/style/style.css' type='text/css' media='all' />
	<link rel='stylesheet' id='toc-screen-css'  href='__HOME__/style/screen.min.css' type='text/css' media='all' />
	<style>.article-content{font-size: 14px;}@media (max-width:640px){.article-content{font-size:16px}}.navbar .logo{width:160px}@media (max-width: 979px){.navbar .logo{width:100%}}</style><!--[if lt IE 9]><script src="__HOME__/js/html5.js"></script><![endif]-->
	<script type="text/javascript" src="/static/ueditor/third-party/SyntaxHighlighter/shCore.js"></script>
	<link rel="stylesheet" href="/static/ueditor/third-party/SyntaxHighlighter/shCoreDefault.css">
	<script type="text/javascript">
		SyntaxHighlighter.all();
	</script>
	<script type="text/javascript" src="__HOME__/js/clipboard.min.js"></script>
</head>
<body class="post-template-default single single-post postid-2117 single-format-standard">
<div class="navbar-wrap">
	{include file="public:head" /}
<header class="header"></header>
<section class="container">
	<div class="content-wrap">
	<div class="content">
		<div class="breadcrumbs">你的位置：
			<a href="<?php echo $config['site_url']?>"><?php echo $config['site_name']?></a> <small>></small>
			<a href="/category/<?php echo $type_seo['type_id']?>"><?php echo $type_seo['type_name']?></a> <small></small>
		</div>
<style>
	.font1{font-weight: bold; color: red; padding-right: 20px;}
	.form{ padding: 20px 0;}
	.form input[type=text]{width: 99%; display: block; border-radius: 5px; height: 35px; line-height: 35px; margin-bottom: 20px;}
	.form textarea{ width: 100%; height: 251px;}
	.form button{width: 150px; height: 40px; line-height: 40px; margin: 20px 0; border: 1px solid #ffffff; background: #333; color: #ffffff; font-weight: bold; font-size: 16px; border-radius: 5px;}
	.form p{ padding: 20px 0;}
	.form p span{ font-size: 12px; padding: 0 15px;}
	.form img{ border: 0; border-radius: 5px;}
	content{ font-size: 18px; line-height: 35px; font-weight: bold;}

</style>
		<article class="article-content">
			<!--<span style="font-weight: bold; color: red; padding-right: 20px;">|</span> 额，学习是一个痛苦并且寂寞的过程，学习中遇到天斩好希望天降大婶，让我坐观大婶破解迷阵，天上有掉馅饼的事儿么，答案是木有，不过世界上好人总是会有的，暂且当王婆一回，我是个热心肠，因此做了这个blog希望力所能及的帮助到大家!<br>-->
			<content><span class="font1">|</span>皇上您来提问，小的尽力为您排忧解难！请提交你的问题我来暂且一试，先说我只能尽力而为，我不是大婶，只是一个希望能帮到你的小白，而且我是不收费的!<br></content>
			<!--<span style="font-weight: bold; color: red; padding-right: 20px;">|</span><span style="border: 1px solid #ccc; padding: 5px; background: #cccc77">Q:</span>你要问那里来的这么好的事儿啊，在这个物质的时代还有人免费打下手的？<br>
			<span style="font-weight: bold; color: red; padding-right: 20px;">|</span><span style="border: 1px solid #ccc; padding: 5px; background: #cccc77">A:</span>只从小的建立了这个blogz之后发现写博文是个比较费神寂寞的事情，尤其是不知道写什么的时候，自己的想法总是有限的，有了你们我就不用担心这个问题了因此我需要你，I need you,I need you！-->
			<form class="form form-horizontal" id="form-rule-add" method="post" action="<?php echo url('index/ask')?>">
				<input type="text" name="title" placeholder="标题：写下您的问题">
				<textarea id="editor" name="content" style="height: 251px;"  placeholder="详细描述你的问题，以便我更好的理解你的问题，问牛答马真尴尬！"></textarea>
				<p><input type="text" name="code" style="width: 20%; display: inline; margin: 0" placeholder="填写验证码"> <img src="{:captcha_src()}" alt="captcha"  id="rands"/><span><a href="javascript:void(0)" onclick="randoms()">看不清，换一张！</a></span></p>
				<button type="submit">提交</button>
			</form>
		</article>

		<footer class="article-footer">
			<?php foreach($article as $v){?>
			<article class="excerpt excerpt-nothumbnail">
				<header><h2><a href="/askArticle/<?php echo $v['id']?>" title="<?php echo $v['title']?>"><?php echo $v['title']?></a></h2></header>
				<p>
				<span class="muted">
				<i class="icon-time icon12"></i> <?php echo formatDate($v['create_time'])?> (<?php echo date('Y-m-d',$v['create_time'])?>)</span>	<span class="muted">
				<i class="icon-eye-open icon12"></i> <?php echo $v['reading_num']?>浏览</span>	<span class="muted">
				<i class="icon-eye-open icon12"></i> <?php echo $v['is_reply'] == 1 ? '<span style="color:red">已回复</span>':'未回复'?></span>
				</p>
			</article>
			<?php } ?>
		</footer>


	</div>
</div>
	<!-------右边开始------->
	<aside class="sidebar">
		{include file="public:right" /}
	</aside>
</section>
	{include file="public:footer" /}
	<script>
		function randoms(){
			var random=Math.floor(Math.random()*1000+1);
			$('#rands').attr("src","/captcha.html"+"?rand="+random);
		};
	</script>

	<script type="text/javascript" charset="utf-8" src="/static/ueditor/ueditor.config.js"></script>
	<script type="text/javascript" charset="utf-8" src="/static/ueditor/ueditor.all.min.js"> </script>
	<script type="text/javascript" charset="utf-8" src="/static/ueditor/lang/zh-cn/zh-cn.js"></script>
	<script type="text/javascript" src="__STATIC_ADMIN__/js/layer.js"></script>
	<script type="text/javascript" src="__STATIC_ADMIN__/js/jQuery.Form.js"></script>
	<script type="text/javascript" src="__STATIC_ADMIN__/js/jquery.validate.js"></script>
	<script type="text/javascript" src="__STATIC_ADMIN__/js/validate-methods.js"></script>
	<script>
		var ue = UE.getEditor('editor', {
			toolbars: [
				['simpleupload']
			],
			autoHeightEnabled: true,
			autoFloatEnabled: true
		});
		$(function(){
			$("#form-rule-add").validate({
				rules:{
					title:{
						required:true,
					},
				},
				submitHandler:function(form){
					/**
					 * 成功之后的回调函数
					 * @type {{success: options.success}}
					 */
					var options = {
						success: function (data) {
							if(data.code==0){
								layer.msg(data.msg,{icon:1,time:1000});
								setInterval("closeWindow()",1000);
							}else{
								layer.msg(data.msg,{icon:5,time:1000});
							}
						}
					};
					$(form).ajaxSubmit(options);
				}
			});
		});
		function closeWindow(){
			window.parent.location.reload();
		}

	</script>

</div>
</body>
</html>
